# 接触到`函数式编程`后，尝试将下面的代码套进该范式里，并尝试理解python`自顶向下设计和自底向上执行`的基本程序设计方法。
# 或许其中有一些不妥当的地方，待以后学识增长后再做改进
# 2021/9/10


import turtle as t

t.pensize(3)
t.speed(10)

def graph():
    n = 0
    colorLs = ["red","blue","green","yellow","purple"]
    stepLs = [3,4,5,6,None]
    for n in range(5):
        t.penup()
        x = 100*n - 200
        t.goto(x,-50)
        t.pendown()
        t.begin_fill()
        color = colorLs[n]
        t.color(color)
        step = stepLs[n]
        t.circle(40,steps=step)
        t.end_fill()

def words():
    t.color("green")
    t.penup()
    t.goto(-100,50)
    t.pendown()
    t.write("Cool Colorful Shapes",font=("Times",18,"bold"))
    t.hideturtle()

def main():
    graph()
    words()
    t.done()

main()
    

